export type QuestionType = "choice" | "programming" | "analysis" | "fill" | "essay";
export type DifficultyLevel = "easy" | "medium" | "hard";

export interface Question {
  id: string;
  type: QuestionType;
  difficulty: DifficultyLevel;
  score: number;
  content: string;
  answer: string;
  knowledge: string[];
  options?: string[];
  analysis?: string;
  tags?: string[];
  createTime: string;
  updateTime: string;
}

export interface ExamTemplate {
  id: string;
  name: string;
  totalScore: number;
  duration: number;
  description?: string;
  difficulty?: string;
  subject?: string;
  tags?: string[];
  createTime?: string;
  updateTime?: string;
  usageCount?: number;
  isDefault?: boolean;
  creator?: string;
  questionDistribution: {
    choice: {
      count: number;
      score: number;
      difficulty: DifficultyLevel[];
    };
    programming: {
      count: number;
      score: number;
      difficulty: DifficultyLevel[];
    };
    analysis: {
      count: number;
      score: number;
      difficulty: DifficultyLevel[];
    };
    fill?: {
      count: number;
      score: number;
      difficulty: DifficultyLevel[];
    };
    essay?: {
      count: number;
      score: number;
      difficulty: DifficultyLevel[];
    };
  };
}
